package com.example.lifecycle.di.app;

import android.content.Context;

import com.example.lifecycle.utils.ToastUtils;

import javax.inject.Singleton;

import dagger.Module;
import dagger.Provides;

@Module
public class AppConfigModule {

    Context context;

    public AppConfigModule(Context context) {
        this.context = context;
    }

    @Singleton
    @Provides
    public Context provideContext() {
        return context;
    }

    @Singleton
    @Provides
    public ToastUtils provideToastUtils() {
        return new ToastUtils(context);
    }
}
